1. Field of the Invention
The present invention is directed to technology for monitoring applications in a computing environment.
2. Description of the Related Art
The growing presence of the Internet as well as other computer networks such as intranets and extranets has brought many new applications in e-commerce, education and other areas. Organizations increasingly rely on such applications to carry out their business or other objectives, and devote considerable resources to ensuring that the applications perform as expected. To this end, various application management techniques have been developed.
For example, for component-based applications, such as those based on Java 2 Platform Enterprise Edition (J2EE), one approach is to collect data about the individual software components that are invoked in an application. A software component generally refers to a software technology for encapsulating software functionality. A software component has characteristics including: multiple-use (reusable), non-context-specific, composable with other components, encapsulated, and a unit of independent deployment and versioning. Alternatively, a component can be considered to be an object written to a specification, such as Java Beans, or the Component Object Model, a Microsoft platform for software componentry. A component can also include a web server or a database, for instance. Software components are typically invoked by processes or threads executing in an application, middleware or other software. For example, for a web-based e-commerce application, a process at an application server is typically initiated by a request to the server, such as a user request to purchase an item. The process may invoke a number of components to carry out the steps necessary to allow the user to purchase the item. For example, a shopping cart component may be used to allow the user to identify the item desired, the payment method and the shipping information. A reservation component may be used to reserve the item while a credit check component verifies the user's credit card information. Once the credit card information is verified, an inventory component is updated based on the item purchased, and a shipping component is invoked to arrange for the item to be shipped, such as by contacting a warehouse. An order completion component may be invoked to confirm the purchase to the user such as by providing an order confirmation number and a tracking number on a web page. Moreover, a given component may be invoked more than once during an application.
In particular, an execution flow can be traced to identify each component that is invoked as well as obtain performance data such as the execution time of each component. An execution flow refers generally to the sequence of steps taken when a computer program executes. Tracing refers to obtaining a detailed record, or trace, of the steps a computer program executes. One type of trace is a stack trace. Traces can be use as an aid in debugging. However, information cannot be obtained and analyzed from every execution flow without maintaining an excessive amount of overhead data and thereby impacting the very application which is being monitored. One way to address this problem is by sampling so that information is obtained regarding every nth execution flow. This approach is problematic because it omits a significant amount of data and, if a particular execution flow instance is not selected for sampling, all information about it is lost. Thus, if a particular component is executing unusually slowly, for instance, but only on an irregular basis, this information may not be captured.
Another approach, aggregation, involves combining information from all execution flows into a small enough data set that can be reported. For example, assume there are one thousand requests to an application server. For each execution flow, performance data such as the response time can be determined. Information such as the slowest, fastest, median and mean response times can then be determined for the aggregated execution flows. However, aggregating more detailed information about the execution flows is more problematic since the details of the execution flows can differ in various ways. Moreover, a mechanism has not been available for aggregating information between related execution flows, such as at different computer systems.
It would be desirable to provide a technique for monitoring execution flows which addresses the above and other issues.